<style type="text/css">
    div#top-left-menu {
        min-width:400px;
        height:28px;
        float:left;
        font-size: 12px;
        line-height: 24px;
    }

    div#top-left-menu ul {
        padding: 3px 0 3px 0; margin: 0;
    }

    div#top-left-menu ul li {
        display: inline;
    }

    div#top-left-menu ul li a {
        color: #ffffff; padding: 6px 0px 4px 6px;  margin-right: 5px;  text-decoration: none;
    }

    div#top-left-menu ul li a:hover, div#top-left-menu ul li a.selected{  color:#cccccc; }

    div#top-right-menu {
        min-width:400px;
        height:28px;
        float:right;
        font-size: 12px;
        line-height: 24px;
    }

    div#top-right-menu ul {
        padding: 3px 0 3px 0; margin: 0;
    }

    div#top-right-menu ul li {
        display: inline;
    }

    div#top-right-menu ul li a {
        color: #ffffff; padding: 6px 0px 4px 6px;  margin-right: 5px;  text-decoration: none;
    }

    div#top-right-menu ul li a:hover, div#top-right-menu ul li a.selected{  color:#cccccc; }

</style>
<div id="top-left-menu">
<?php
  $query = "SELECT title,link,parentid,level FROM menu where menutypeid = 1 and isactive = 1 and isdeleted = 0  ORDER BY level";
  $result = mysql_query($query);
?>
<ul style="text-align: left;">
<?php
  while($field=mysql_fetch_array($result)){
    echo "<li><a href=\"". $field[link]. "\">" . $field[title] ."</a></li>";
    echo "|";
  }
  echo "</ul>";
?>
</div>


<div id="top-right-menu">
<?php
$query = "SELECT title,link,parentid,level FROM menu where menutypeid = 2 and isactive = 1 and isdeleted = 0  ORDER BY level";
$result = mysql_query($query);
//echo $result;


echo "<ul style=\"text-align:right; \">";
while($field=mysql_fetch_array($result)){
echo "<li><a href=\"". $field[link]. "\">" . $field[title] ."</a></li>";
echo "|";
}
echo "</ul>";
?>
</div>

